<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>JSDoc: Class: Branch</title>
    
    <script src="scripts/prettify/prettify.js"> </script>
    <script src="scripts/prettify/lang-css.js"> </script>
    <!--[if lt IE 9]>
      <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
    <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>

<body>

<div id="main">
    
    <h1 class="page-title">Class: Branch</h1>
    
    



<section>
    
<header>
    <h2>
    Branch
    </h2>
    
</header>  

<article>
    <div class="container-overview">
    
    
    
        
<dt>
    <h4 class="name" id="Branch"><span class="type-signature"></span>new Branch<span class="signature">(options)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            
            
            <td class="description last"><p>Options of branch</p>
                <h6>Properties</h6>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>parent</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="GitGraph.html">GitGraph</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>GitGraph constructor</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>parentBranch</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="Branch.html">Branch</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    options.parentCommit.branch
                
                </td>
            
            
            <td class="description last"><p>Parent branch</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>parentCommit</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="Commit.html">Commit</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    _getLast(options.parentBranch.commits)
                
                </td>
            
            
            <td class="description last"><p>Parent commit</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>name</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    "no-name"
                
                </td>
            
            
            <td class="description last"><p>Branch name</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>commitDefaultOptions</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    {}
                
                </td>
            
            
            <td class="description last"><p>Default options for commits</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line468">line 468</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

    
    </div>
    
    
    
    
    
    
    
    
    
    
    
    
    
    
        <h3 class="subsection-title">Methods</h3>
        
        <dl>
            
<dt>
    <h4 class="name" id="branch"><span class="type-signature"></span>branch<span class="signature">(options)</span><span class="type-signature"> &rarr; {<a href="Branch.html">Branch</a>}</span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Create new branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Object</span>


            
            </td>
            
            
            
            
            
            <td class="description last"><p>Branch name | Options of Branch</p></td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line558">line 558</a>
    </li></ul></dd>
    
    
    
    
    
    <dt class="tag-see">See:</dt>
    <dd class="tag-see">
        <ul>
            <li><a href="Branch.html">Branch</a></li>
        </ul>
    </dd>
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    
            
<div class="param-desc">
    <p>New Branch</p>
</div>



<dl>
	<dt>
		Type
	</dt>
	<dd>
		
<span class="param-type"><a href="Branch.html">Branch</a></span>


	</dd>
</dl>

        
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="calculColumn"><span class="type-signature"></span>calculColumn<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Calcul column</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line922">line 922</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="checkout"><span class="type-signature"></span>checkout<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Checkout onto this branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line807">line 807</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="commit"><span class="type-signature"></span>commit<span class="signature">(<span class="optional">options</span>)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Add a commit</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Message | Options of commit</p>
                <h6>Properties</h6>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>detailId</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Id of detail DOM Element</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line632">line 632</a>
    </li></ul></dd>
    
    
    
    
    
    <dt class="tag-see">See:</dt>
    <dd class="tag-see">
        <ul>
            <li><a href="Commit.html">Commit</a></li>
        </ul>
    </dd>
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="delete"><span class="type-signature"></span>delete<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Delete this branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line816">line 816</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="merge"><span class="type-signature"></span>merge<span class="signature">(<span class="optional">target</span>, <span class="optional">commitOptions</span>)</span><span class="type-signature"> &rarr; {<a href="Branch.html">Branch</a>}</span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Merge branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>target</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="Branch.html">Branch</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.parent.HEAD
                
                </td>
            
            
            <td class="description last"></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>commitOptions</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Message | Options of commit</p>
                <h6>Properties</h6>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>fastForward</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    false
                
                </td>
            
            
            <td class="description last"><p>If true, merge should use fast-forward if possible</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line831">line 831</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    <h5>Returns:</h5>
    
            
<div class="param-desc">
    <p>this</p>
</div>



<dl>
	<dt>
		Type
	</dt>
	<dd>
		
<span class="param-type"><a href="Branch.html">Branch</a></span>


	</dd>
</dl>

        
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="pushPath"><span class="type-signature"></span>pushPath<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Push a new point to path.
This method will combine duplicate points and reject reversed points.</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line947">line 947</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="render"><span class="type-signature"></span>render<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Render the branch</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line583">line 583</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="tag"><span class="type-signature"></span>tag<span class="signature">(<span class="optional">options</span>)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Tag the last commit of the branch.</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Branch.html">Branch</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>
|

<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Message | Options of the tag</p>
                <h6>Properties</h6>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>tag</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Message of the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tagColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Color of the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tagFont</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>Font of the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>displayTagBox</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
            
            <td class="description last"><p>If true, display a box around the tag</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line783">line 783</a>
    </li></ul></dd>
    
    
    
    
    
    <dt class="tag-see">See:</dt>
    <dd class="tag-see">
        <ul>
            <li><a href="Tag.html">Tag</a></li>
        </ul>
    </dd>
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        </dl>
    
    
    
    
    
</article>

</section>  




</div>

<nav>
    <h2><a href="index.html">Index</a></h2><h3>Classes</h3><ul><li><a href="Branch.html">Branch</a></li><li><a href="Commit.html">Commit</a></li><li><a href="GitGraph.html">GitGraph</a></li><li><a href="Tag.html">Tag</a></li><li><a href="Template.html">Template</a></li></ul><h3>Global</h3><ul><li><a href="global.html#_assignTagOptionsToCommit">_assignTagOptionsToCommit</a></li><li><a href="global.html#_booleanOptionOr">_booleanOptionOr</a></li><li><a href="global.html#_clone">_clone</a></li><li><a href="global.html#_drawTextBG">_drawTextBG</a></li><li><a href="global.html#_emitEvent">_emitEvent</a></li><li><a href="global.html#_getFontHeight">_getFontHeight</a></li><li><a href="global.html#_getLast">_getLast</a></li><li><a href="global.html#_getParentCommitFromBranch">_getParentCommitFromBranch</a></li><li><a href="global.html#_getScale">_getScale</a></li><li><a href="global.html#_isHorizontal">_isHorizontal</a></li><li><a href="global.html#_isNullOrUndefined">_isNullOrUndefined</a></li><li><a href="global.html#_isObject">_isObject</a></li><li><a href="global.html#_isVertical">_isVertical</a></li></ul>
</nav>

<br clear="both">

<footer>
    Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.2.2</a> on Fri Jan 06 2017 09:40:41 GMT+0100 (CET)
</footer>

<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>